//
//  ViewController.m
//  HKiOSTools
//
//  Created by 胡锦涛 on 2020/12/6.
//

#import "ViewController.h"
#import "UIImageView+HKLoadImage.h"
@interface ViewController ()
/** 标签 */
@property (nonatomic, strong) UILabel * label ;
/** 修改主题 */
@property (nonatomic, strong) UIButton * themeButton ;
/// 图片
@property (nonatomic, strong) UIImageView * imageView ;
@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.view.backgroundColor = HKHexString(@"55c9c4");
    _label = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT)];
    _label.text = @"你好啊！！！";
    _label.textAlignment = NSTextAlignmentCenter;
    _label.font = [UIFont qmui_lightSystemFontOfSize:20];
    _label.center = CGPointMake(SCREEN_WIDTH/2, SCREEN_WIDTH/2);
    _label.textColor = UIColor.hk_titleTextColor;
    [self.view addSubview:_label];
    
    _themeButton = [UIButton buttonWithType:UIButtonTypeCustom];
    _themeButton.frame = CGRectMake(20, HK_NAVBAR_HEIGHT, 200, 40);
    [_themeButton hk_setNormalTitle:@"换主题"];
    _themeButton.backgroundColor = UIColor.hk_backgroundColor;
    [_themeButton hk_addTarget:self action:@selector(changeTheme)];
    [self.view addSubview:_themeButton];
}
- (void)changeTheme {
    QMUIThemeManagerCenter.defaultThemeManager.currentThemeIdentifier = @"Dark";
}

@end
